﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using YmatouSeller.NoticeAPI.Model.Entity;
using YmatouSeller.NoticeAPI.Model.Enums;


namespace YmatouSeller.Notice.ApplicationService.Interface
{
    public interface ISystemNoticeManageService
    {
        #region 消息通知管理
        /// <summary>
        /// 获取国家信息
        /// </summary>
        /// <returns></returns>
        List<CountryInfo> GetAllCountry(string continent, int countryID, int selectType);

        /// <summary>
        /// 根据用户名获取用户ID
        /// </summary>
        /// <param name="loginIds"></param>
        /// <returns></returns>
        List<UserInfo> GetUserIDLstByLoginIds(List<string> loginIds,int idType);

        /// <summary>
        /// 上传文件
        /// </summary>
        /// <param name="fileData"></param>
        /// <param name="fileName"></param>
        /// <param name="fileType">1图片，2文件</param>
        /// <returns></returns>
        string UploadFile(byte[] fileData, string fileName, int fileType);

        /// <summary>
        /// 删除通知附件
        /// </summary>
        /// <param name="detailModle"></param>
        /// <param name="param"></param>
        /// <returns></returns>
        bool DeleteNoticeAttachment(List<long> noticeOptionIds, string noticeId);

        /// <summary>
        /// 保存通知消息
        /// </summary>
        /// <param name="detailModle"></param>
        /// <returns></returns>
        bool SaveSystemNotice(SystemNoticeDetail detailModle, ref string msg);

        /// <summary>
        /// 获取通知消息详情
        /// </summary>
        /// <param name="noticeId"></param>
        /// <returns></returns>
        SystemNoticeDetail GetSystemNoticeItem(string noticeId);

        /// <summary>
        /// 获取通知消息
        /// </summary>
        /// <param name="noticeTitle"></param>
        /// <param name="noticeType"></param>
        /// <param name="beginTime"></param>
        /// <param name="endTime"></param>
        /// <param name="pageIndex"></param>
        /// <param name="pageSize"></param>
        /// <param name="totalCount"></param>
        /// <returns></returns>
        List<SystemNotice> GetSystemNoticeList(string noticeTitle, NoticeTypeEnum noticeType, DateTime? beginTime, DateTime? endTime, int pageIndex, int pageSize, out int totalCount);

        #endregion

        /// <summary>
        /// 阅读通知保存
        /// </summary>
        /// <param name="sellerid"></param>
        /// <param name="noticeid"></param>
        /// <returns></returns>
        bool SubmitReadNotice(int sellerid, string noticeid, string resource);

        /// <summary>
        /// 获取未读数
        /// </summary>
        /// <param name="state"></param>
        /// <param name="sellerid"></param>
        int GetUnReadNoticeCount(string continent, int sellerid);

        /// <summary>
        /// 获取跑马灯
        /// </summary>
        /// <param name="state"></param>
        /// <param name="sellerid"></param>
        /// <returns></returns>
        List<SystemNotice> GetMoveNoticeList(string state, int sellerid);

        /// <summary>
        /// 获取全部通知list
        /// </summary>
        /// <param name="state"></param>
        /// <param name="sellerid"></param>
        /// <param name="noticeType"></param>
        /// <param name="total"></param>
        /// <returns></returns>
        List<SystemNotice> GetSellerAllNoticeList(string state, int sellerid, int noticeType, int total);
        /// <summary>
        /// 通知详情更多
        /// </summary>
        /// <param name="sellerid"></param>
        /// <param name="state"></param>
        /// <param name="noticeType"></param>
        /// <param name="beginTime"></param>
        /// <param name="endTime"></param>
        /// <param name="pageIndex"></param>
        /// <param name="pageSize"></param>
        /// <param name="totalCount"></param>
        /// <returns></returns>
        List<SystemNoticeTypeEntity> GetSystemNoticeDetailList(int sellerid, string state, NoticeTypeEnum noticeType,
            DateTime? beginTime, DateTime? endTime, int pageIndex, int pageSize, out int totalCount);

        /// <summary>
        /// 根据买手id去获取买手相关的信息，暂时是区域，可以扩展
        /// </summary>
        /// <param name="sellerid"></param>
        /// <returns></returns>
        string GetSellerInfo(int sellerid);

        List<NoticeTypeEntity> GetNoticeTypeList(int sellerid, string state);

    }
}
